from sqlalchemy import Column, Integer, String

from app.models.base import BaseModel


class SkuSaleAttributeValueDo(BaseModel):
    __tablename__ = "sku_sale_attribute_value"
    __table_args__ = {"comment": "SKU销售属性&值"}

    id = Column(Integer, primary_key=True, autoincrement=True, comment='主键ID')
    sku_id = Column(Integer, nullable=True, index=True, comment='SKU id')
    attr_id = Column(Integer, nullable=True, index=True, comment='属性id')
    attr_name = Column(String(200), nullable=True, comment='销售属性名')
    attr_value = Column(String(200), nullable=True, comment='销售属性值')
    attr_sort = Column(Integer, nullable=True, comment='排序')